package com.ccb.sc.common.modules.goods.enums;

import com.baomidou.mybatisplus.annotation.IEnum;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;

/**
 * @author ken
 * @since 2020-09-15
 */
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
@Getter
public enum GoodsStatus implements IEnum<Integer> {

    /**
     * 草稿
     */
    DRAFT(1, "草稿"),

    /**
     * 审核中
     */
    WAITAUDIT(2, "待审核"),

    /**
     * 审核未通过
     */
    REFUSED(3, "审核未通过"),

    /**
     * 已上架
     */
    ON_SALE(4, "已上架"),

    /**
     * 已下架
     */
    OFF_SALE(5, "已下架"),

    ;

    private int value;
    private String desc;

    GoodsStatus(int value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    @Override
    public Integer getValue() {
        return this.value;
    }
}
